home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / SLAX 6.0.8 / slax-6.0.8.iso / slax / base / 006-devel.lzm / usr / include / ntfs-3g / compat.h < prev    next >
Encoding:
C/C++ Source or Header  |  2008-10-26  |  1.6 KB  |  62 lines

  1. /*
  2.  * compat.h - Tweaks for Windows compatibility.
  3.  *
  4.  * Copyright (c) 2002 Richard Russon
  5.  * Copyright (c) 2002-2004 Anton Altaparmakov
  6.  *
  7.  * This program/include file is free software; you can redistribute it and/or
  8.  * modify it under the terms of the GNU General Public License as published
  9.  * by the Free Software Foundation; either version 2 of the License, or
  10.  * (at your option) any later version.
  11.  *
  12.  * This program/include file is distributed in the hope that it will be
  13.  * useful, but WITHOUT ANY WARRANTY; without even the implied warranty
  14.  * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  15.  * GNU General Public License for more details.
  16.  *
  17.  * You should have received a copy of the GNU General Public License
  18.  * along with this program (in the main directory of the NTFS-3G
  19.  * distribution in the file COPYING); if not, write to the Free Software
  20.  * Foundation,Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  21.  */
  22.  
  23. #ifndef _NTFS_COMPAT_H
  24. #define _NTFS_COMPAT_H
  25.  
  26. #ifdef HAVE_CONFIG_H
  27. #include "config.h"
  28. #endif
  29.  
  30. #ifndef HAVE_FFS
  31. extern int ffs(int i);
  32. #endif /* HAVE_FFS */
  33.  
  34. #ifndef HAVE_DAEMON
  35. extern int daemon(int nochdir, int noclose);
  36. #endif /* HAVE_DAEMON */
  37.  
  38. #ifndef HAVE_STRSEP
  39. extern char *strsep(char **stringp, const char *delim);
  40. #endif /* HAVE_STRSEP */
  41.  
  42. #ifdef WINDOWS
  43.  
  44. #define HAVE_STDIO_H        /* mimic config.h */
  45. #define HAVE_STDARG_H
  46.  
  47. #define atoll            _atoi64
  48. #define fdatasync        commit
  49. #define __inline__        inline
  50. #define __attribute__(X)    /*nothing*/
  51.  
  52. #else /* !defined WINDOWS */
  53.  
  54. #ifndef O_BINARY
  55. #define O_BINARY        0        /* unix is binary by default */
  56. #endif
  57.  
  58. #endif /* defined WINDOWS */
  59.  
  60. #endif /* defined _NTFS_COMPAT_H */
  61.  
  62.